package com.xander.qqdatabase.service.impl;

import com.xander.qqdatabase.entity.QunInfo;
import com.xander.qqdatabase.enums.ErrorCodeEnum;
import com.xander.qqdatabase.mapper.QunInfoMapper;
import com.xander.qqdatabase.service.QunInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import static com.xander.qqdatabase.util.CheckUtil.*;

/**
 * @author 叶振东
 * @date 2019-01-23
 */
@Service
public class QunInfoServiceImpl implements QunInfoService {
    @Autowired
    private QunInfoMapper qunInfoMapper;

    @Override
    public QunInfo getQunInfo(Integer qun) {
        check(qun!=null, ErrorCodeEnum.PARAMETER_EMPTY,"","");
        return qunInfoMapper.getQunInfo(qun);
    }
}
